package oop.controller.action.sectstruct;

import oop.controller.action.DefaultAction;
import oop.db.dao.SectionStructureDAO;

public class DeleteAction extends DefaultAction {

	@Override
	public void performImpl() throws Exception {
		long sectionStructureId = Long
				.parseLong(request.getParameter("ssd_id"));
		SectionStructureDAO.drop(sectionStructureId);

		long testStructureId = Long.parseLong(request
				.getParameter("ssd_testid"));
		setNextAction("teststruct.view&tsv_id=" + testStructureId);

		SectionStructureDAO.drop(sectionStructureId);

		setNextAction("teststruct.view&tsv_id=" + testStructureId);
	}

}
